package cn.tedu.tmall.passport.dao.persist.repository.impl;

import cn.tedu.tmall.passport.dao.persist.mapper.AdminMapper;
import cn.tedu.tmall.passport.dao.persist.mapper.StaffMapper;
import cn.tedu.tmall.passport.dao.persist.repository.IAdminRepository;
import cn.tedu.tmall.passport.dao.persist.repository.IStaffRepository;
import cn.tedu.tmall.passport.pojo.entity.Admin;
import cn.tedu.tmall.passport.pojo.entity.Staff;
import cn.tedu.tmall.passport.pojo.vo.AdminLoginInfoVO;
import cn.tedu.tmall.passport.pojo.vo.StaffLoginInfoVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

@Repository
public class AdminRepositoryImpl implements IAdminRepository {

    @Autowired
    private AdminMapper adminMapper;

    //用户注册
    @Override
    public int adminReg(Admin admin) {
        return adminMapper.insert(admin);
    }

    @Override
    public AdminLoginInfoVO getLoginInfoByUsername(String username) {
        return adminMapper.getLoginInfoByUsername(username);
    }
    /*@Override
    public UserLoginInfoVO getLoginInfoByPhone(String phone) {
        return userMapper.getLoginInfoByPhone(phone);
    }*/


}
